home *** CD-ROM | disk | FTP | other *** search
/ IRIX Base Documentation 2002 November / SGI IRIX Base Documentation 2002 November.iso / usr / share / catman / p_man / cat3dm / compression / cl_impactcomp.z / cl_impactcomp
Encoding:
Text File  |  2002-10-03  |  14.2 KB  |  265 lines

  1.  
  2.  
  3.  
  4. ccccllll____iiiimmmmppppaaaaccccttttccccoooommmmpppp((((3333ddddmmmm))))                                          ccccllll____iiiimmmmppppaaaaccccttttccccoooommmmpppp((((3333ddddmmmm))))
  5.  
  6.  
  7.  
  8. NNNNAAAAMMMMEEEE
  9.      cl_impactcomp - IMPACT Compression JPEG Accelerator (in the Compression
  10.      Library)
  11.  
  12. SSSSYYYYNNNNOOOOPPPPSSSSIIIISSSS
  13.      ####iiiinnnncccclllluuuuddddeeee <<<<ddddmmmmeeeeddddiiiiaaaa////ccccllll....hhhh>>>>
  14.  
  15.      ####iiiinnnncccclllluuuuddddeeee <<<<ddddmmmmeeeeddddiiiiaaaa////ccccllll____iiiimmmmppppaaaaccccttttccccoooommmmpppp....hhhh>>>>
  16.  
  17. DDDDEEEESSSSCCCCRRRRIIIIPPPPTTTTIIIIOOOONNNN
  18.      IMPACT Compression is an optional hardware accelerator for JPEG image
  19.      compression.  The programming interface to impactcomp is via the standard
  20.      Compression Library.  For overviews of the JPEG standard and the CL API,
  21.      see _j_p_e_g(4) and _C_L_i_n_t_r_o(3dm).
  22.  
  23.      Impactcomp implements a subset of the JPEG standard optimized for video
  24.      originated images.  This subset is baseline JPEG, interleaved YCrCb, 8-
  25.      bits per component.  Impactcomp is capable of compressing and
  26.      decompressing to and from memory, or to and from the video hardware
  27.      present on impactcomp or an IMPACT Video option.
  28.  
  29.      Impactcomp also supports an arbitrary scale down and clip of images being
  30.      decompressed to memory.  This scaling happens without any performance
  31.      penalty and produces high quality results.
  32.  
  33.  
  34. PPPPRRRROOOOGGGGRRRRAAAAMMMMMMMMIIIINNNNGGGG IIIIMMMMPPPPAAAACCCCTTTT CCCCOOOOMMMMPPPPRRRREEEESSSSSSSSIIIIOOOONNNN
  35.      IMPACT Compression is programmed via the Compression Library (CL)
  36.      utilizing the base CL API as well as JPEG-specific and impactcomp-
  37.      specific parameters.
  38.  
  39.  
  40.    UUUUSSSSIIIINNNNGGGG IIIIMMMMPPPPAAAACCCCTTTTCCCCOOOOMMMMPPPP
  41.      The IMPACT Compression JPEG Codec is invoked by first querying the
  42.      compression library for the scheme named "impact" using
  43.      ccccllllQQQQuuuueeeerrrryyyySSSScccchhhheeeemmmmeeeeFFFFrrrroooommmmNNNNaaaammmmeeee....  The application then specifies this scheme
  44.      argument to ccccllllOOOOppppeeeennnnCCCCoooommmmpppprrrreeeessssssssoooorrrr....  At most two applications can have
  45.      impactcomp open at a time.  An error will be returned if both channels
  46.      are busy.
  47.  
  48.  
  49.    SSSSEEEETTTTTTTTIIIINNNNGGGG UUUUPPPP TTTTRRRRAAAANNNNSSSSFFFFEEEERRRRSSSS
  50.      Impactcomp is capable of four different modes of operation.  Video can be
  51.      compressed to a memory buffer, a memory buffer can be decompressed and
  52.      sent out to video, an image in memory can be compressed to memory, and a
  53.      compressed image can be decompressed to memory.  Video data is always
  54.      treated as non-interleaved fields.
  55.  
  56.      Memory to memory transfers may be initiated using the standard CL calls.
  57.      The size of the uncompressed image must not be larger than 4080 pixels
  58.      wide by 4088 lines high.  The uncompressed data format must be either
  59.      CL_FORMAT_YCbCr422 or CL_FORMAT_XBGR.
  60.  
  61.  
  62.  
  63.                                                                         PPPPaaaaggggeeee 1111
  64.  
  65.  
  66.  
  67.  
  68.  
  69.  
  70. ccccllll____iiiimmmmppppaaaaccccttttccccoooommmmpppp((((3333ddddmmmm))))                                          ccccllll____iiiimmmmppppaaaaccccttttccccoooommmmpppp((((3333ddddmmmm))))
  71.  
  72.  
  73.  
  74.      Transfers to and from video must use the CL direct buffered interface
  75.      specifying CL_EXTERNAL_DEVICE as the _f_r_a_m_e_B_u_f_f_e_r parameter to ccccllllCCCCoooommmmpppprrrreeeessssssss
  76.      or ccccllllDDDDeeeeccccoooommmmpppprrrreeeessssssss.  Additionally, the call to ccccllllDDDDeeeeccccoooommmmpppprrrreeeessssssss or ccccllllCCCCoooommmmpppprrrreeeessssssss
  77.      should either be made by a separate thread within the program or with
  78.      CL_CONTINUOUS_NONBLOCK as the frame count parameter since it will not
  79.      return until the transfer is complete.
  80.  
  81.  
  82.    PPPPAAAARRRRAAAAMMMMEEEETTTTEEEERRRRSSSS :::: GGGGEEEENNNNEEEERRRRAAAALLLL CCCCLLLL
  83.      The following general CL parameters are useful for Impactcomp. For more
  84.      information, see _C_L_i_n_t_r_o(3dm).
  85.  
  86.      CCCCLLLL____IIIIMMMMAAAAGGGGEEEE____WWWWIIIIDDDDTTTTHHHH
  87.           Uncompressed image width, in pixels.  When transfering to or from
  88.           video using NTSC timing, the width must be 640.  When transfering to
  89.           or from video using PAL timing, the width must be 768.  When
  90.           transfering to or from video using CCIR timing, the width must be
  91.           720.  The width must always be a multiple of 16.
  92.  
  93.      CCCCLLLL____IIIIMMMMAAAAGGGGEEEE____HHHHEEEEIIIIGGGGHHHHTTTT
  94.           Uncompressed image height in pixels.  Since Impactcomp deals in
  95.           fields which represent every other line of a video frame, the image
  96.           height is half of the full frame height.  The height must always be
  97.           a multiple of 8.  The video port on Impactcomp transmits 243 lines
  98.           per field in NTSC mode which is not a multiple of 8.  Applications
  99.           should therefore either specify 240 or 248 as the height for NTSC or
  100.           CCIR(525).  The height for PAL or CCIR(625) should be 288.
  101.  
  102.      CCCCLLLL____IIIINNNNTTTTEEEERRRRNNNNAAAALLLL____IIIIMMMMAAAAGGGGEEEE____WWWWIIIIDDDDTTTTHHHH
  103.           Width of compressed image.  This is normally the same as
  104.           CL_IMAGE_WIDTH, but may be different when scaling is used.
  105.           Impactcomp has two types of image scaling capability.  When
  106.           decompressing from memory to memory, the image may be downsized from
  107.           the original.  This mode of scaling is enabled by setting
  108.           CL_IMAGE_WIDTH to the desired reduced size while setting
  109.           CL_INTERNAL_IMAGE_WIDTH to the original size contained in the JPEG
  110.           data.  When compressing or decompressing from external video,
  111.           Impactcomp supports a limited form of scaling.  If the
  112.           CL_IMAGE_WIDTH is set to the width of the video field (either 640,
  113.           704 or 768), and CL_INTERNAL_IMAGE_WIDTH is set to one half of that
  114.           (either 320, 352 or 384), then Impactcomp will scale the image by a
  115.           factor of two.  It is only necessary to set this parameter if one of
  116.           these two types of scaling is desired.
  117.  
  118.      CCCCLLLL____IIIINNNNTTTTEEEERRRRNNNNAAAALLLL____IIIIMMMMAAAAGGGGEEEE____HHHHEEEEIIIIGGGGHHHHTTTT
  119.           Height of compressed image.  This is normally the same as
  120.           CL_IMAGE_HEIGHT, but may be different when scaling is used.  See the
  121.           discussion of CL_INTERNAL_IMAGE_WIDTH above.
  122.  
  123.      CCCCLLLL____FFFFOOOORRRRMMMMAAAATTTT
  124.           When decompressing or compressing to or from memory, Impactcomp
  125.           recognizes 32-bit RGB pixels (CL_FORMAT_XBGR), or 16-bit YCbCr
  126.  
  127.  
  128.  
  129.                                                                         PPPPaaaaggggeeee 2222
  130.  
  131.  
  132.  
  133.  
  134.  
  135.  
  136. ccccllll____iiiimmmmppppaaaaccccttttccccoooommmmpppp((((3333ddddmmmm))))                                          ccccllll____iiiimmmmppppaaaaccccttttccccoooommmmpppp((((3333ddddmmmm))))
  137.  
  138.  
  139.  
  140.           pixels (CL_FORMAT_YCbCr422).
  141.  
  142.      CCCCLLLL____AAAALLLLGGGGOOOORRRRIIIITTTTHHHHMMMM____IIIIDDDD
  143.           _I_M_P_A_C_T _C_o_m_p_r_e_s_s_i_o_n does not have a fixed algorithm identifier.
  144.           Applications must use ccccllllQQQQuuuueeeerrrryyyySSSScccchhhheeeemmmmeeeeFFFFrrrroooommmmNNNNaaaammmmeeee to determine the
  145.           appropriate scheme on each machine.
  146.  
  147.      CCCCLLLL____OOOORRRRIIIIEEEENNNNTTTTAAAATTTTIIIIOOOONNNN
  148.           IMPACT Compression is capable of handling both ``top down'' and
  149.           ``bottom up'' image formats for uncompressed data only.  Compressed
  150.           data is in all cases ``top down''.
  151.  
  152.      CCCCLLLL____EEEENNNNAAAABBBBLLLLEEEE____IIIIMMMMAAAAGGGGEEEEIIIINNNNFFFFOOOO
  153.           Setting this parameter to ``TRUE'' enables the
  154.           ccccllllGGGGeeeettttNNNNeeeexxxxttttIIIImmmmaaaaggggeeeeIIIInnnnffffoooo(3dm) CL function which can be used to retrieve
  155.           time stamp and other information about compressed fields. In the
  156.           case of Impactcomp compressing from external video, the time stamp
  157.           returned represents the time at which the first line of the
  158.           uncompressed field arrived at the Impactcomp board.
  159.  
  160.  
  161.    PPPPAAAARRRRAAAAMMMMEEEETTTTEEEERRRRSSSS :::: JJJJPPPPEEEEGGGG
  162.      The following JPEG parameters may also be used.  See _c_l__j_p_e_g(3dm) for
  163.      descriptions.
  164.  
  165.      CCCCLLLL____JJJJPPPPEEEEGGGG____QQQQUUUUAAAALLLLIIIITTTTYYYY____FFFFAAAACCCCTTTTOOOORRRR
  166.  
  167.      CCCCLLLL____JJJJPPPPEEEEGGGG____QQQQUUUUAAAANNNNTTTTIIIIZZZZAAAATTTTIIIIOOOONNNN____TTTTAAAABBBBLLLLEEEESSSS
  168.  
  169.      CCCCLLLL____JJJJPPPPEEEEGGGG____SSSSTTTTRRRREEEEAAAAMMMM____HHHHEEEEAAAADDDDEEEERRRRSSSS
  170.  
  171.  
  172.    PPPPAAAARRRRAAAAMMMMEEEETTTTEEEERRRRSSSS :::: IIIIMMMMPPPPAAAACCCCTTTTCCCCOOOOMMMMPPPP
  173.      These parameters are specific to IMPACT Compression.
  174.  
  175.      CCCCLLLL____IIIIMMMMPPPPAAAACCCCTTTT____VVVVIIIIDDDDEEEEOOOO____IIIINNNNPPPPUUUUTTTT____CCCCOOOONNNNTTTTRRRROOOOLLLL
  176.           Type: CL_ENUM_VALUE
  177.           Gets and sets the codec channel in use by this handle.  The value
  178.           of this parameter is a cookie to be provided to the Video Library (VL)
  179.           when CL_EXTERNAL_DEVICE is used.
  180.  
  181.      CCCCLLLL____IIIIMMMMPPPPAAAACCCCTTTT____VVVVIIIIDDDDEEEEOOOO____IIIINNNNPPPPUUUUTTTT____CCCCOOOONNNNTTTTRRRROOOOLLLL
  182.           Type: CL_ENUM_VALUE
  183.           Controls operation of the codec. If this parameter is set to CL_IMPACT_STOP
  184.           prior to a call to clCompress/clDecompress, processing will pause until
  185.           set to the value CL_IMPACT_START.  After clCompress/clDecompress has
  186.           been called, when this parameter is set to CL_IMPACT_STOP, the codec will
  187.           stop processing.
  188.  
  189.      CCCCLLLL____IIIIMMMMPPPPAAAACCCCTTTT____FFFFRRRRAAAAMMMMEEEE____IIIINNNNTTTTEEEERRRRLLLLEEEEAAAAVVVVEEEE
  190.           Type: CL_RANGE_VALUE
  191.           In memory-to-memory operations, it is possible to access the uncompressed
  192.  
  193.  
  194.  
  195.                                                                         PPPPaaaaggggeeee 3333
  196.  
  197.  
  198.  
  199.  
  200.  
  201.  
  202. ccccllll____iiiimmmmppppaaaaccccttttccccoooommmmpppp((((3333ddddmmmm))))                                          ccccllll____iiiimmmmppppaaaaccccttttccccoooommmmpppp((((3333ddddmmmm))))
  203.  
  204.  
  205.  
  206.           images as interleaved frames, which are de-interleaved during compression
  207.           or interleaved during decompression.  These operations are performed when
  208.           this parameter has the value TRUE.
  209.  
  210.      CCCCLLLL____IIIIMMMMPPPPAAAACCCCTTTT____IIIINNNNTTTTEEEERRRRLLLLEEEEAAAAVVVVEEEE____MMMMOOOODDDDEEEE
  211.           Type: CL_ENUM_VALUE
  212.           When using CL_IMPACT_FRAME_INTERLEAVE, this parameter specifies which
  213.           of the decompressed images is the top-most line. If the first (and all
  214.           subsequent odd numbered fields) occupies the top line of the uncompressed
  215.           image, use CL_IMPACT_INTERLEAVE_ODD.  Use CL_IMPACT_INTERLEAVE_EVEN for
  216.           the case where even numbered fields occupy the top-most line of the
  217.           uncompressed image.
  218.  
  219.  
  220.    CCCCOOOONNNNNNNNEEEECCCCTTTTIIIINNNNGGGG TTTTOOOO VVVVIIIIDDDDEEEEOOOO
  221.      The IMPACT Compression option has built-in analog video I/O, and, if
  222.      installed, a direct connection to IMPACT Video.  Applications need to
  223.      talk with both the Compression LIbrary and the Video Library (VL) to
  224.      perform video I/O.
  225.  
  226.      An application needs to query the CL parameter
  227.      CL_IMPACT_VIDEO_INPUT_CONTROL, and in turn, pass the returned value to
  228.      the vlGetNode() routine as the VL_CODEC node to open.
  229.  
  230.      See _i_m_p_a_c_t_v_i_d_e_o(7), _i_m_p_a_c_t_c_o_m_p(7), and _v_l(3dm) for more information, and
  231.      the example applications in
  232.      /usr/people/4Dgifts/examples/dmedia/compression/impact
  233.  
  234. FFFFIIIILLLLEEEESSSS
  235.      /usr/include/dmedia/cl.h /usr/include/dmedia/cl_impactcomp.h
  236.  
  237.  
  238. SSSSEEEEEEEE AAAALLLLSSSSOOOO
  239.      jpeg(4), CLintro(3dm), cl_jpeg(3dm),
  240.      vl(3dm), impactvideo(7), impactcomp(7)
  241.  
  242.  
  243.  
  244.  
  245.  
  246.  
  247.  
  248.  
  249.  
  250.  
  251.  
  252.  
  253.  
  254.  
  255.  
  256.  
  257.  
  258.  
  259.  
  260.  
  261.                                                                         PPPPaaaaggggeeee 4444
  262.  
  263.  
  264.  
  265.